#!/bin/bash
rm -rf ai-web-admin-moshare.zip
#pnpm build
#cd dist
zip ai-web-admin-moshare.zip -r . -x "node_modules/*"
ssh gptuser@47.106.247.46 "mkdir -p /mnt/gpt/ai-web-admin-moshare/ && rm -rf /mnt/gpt/ai-web-admin-moshare/*"
scp ai-web-admin-moshare.zip gptuser@47.106.247.46:/mnt/gpt/ai-web-admin-moshare/
rm -rf ai-web-admin-moshare.zip
scp autoDeploy_moshare.sh gptuser@47.106.247.46:/mnt/gpt/ai-web-admin-moshare/
ssh gptuser@47.106.247.46 "cd /mnt/gpt/ai-web-admin-moshare/ && chmod -R a+x * && sh autoDeploy_moshare.sh"
